from flower import models
from rest_framework import serializers
class PurposeSerializer(serializers.ModelSerializer):
    class Meta:
        model = models.Purpose
        fields = '__all__'

class FlowerSerializer(serializers.ModelSerializer):
    class Meta:
        model = models.Flower
        fields = '__all__'

class FlowerCartSerializer(serializers.ModelSerializer):
    class Meta:
        model = models.MyCart
        fields = '__all__'

class MyCartSerializer(serializers.ModelSerializer):
    flower=FlowerSerializer()
    class Meta:
        model = models.MyCart
        fields = '__all__'

class MyOrderSerializer(serializers.ModelSerializer):
    class Meta:
        model = models.MyOrder
        fields = '__all__'
class MyDetailSerializer(serializers.ModelSerializer):
    class Meta:
        model = models.MyDetail
        fields = '__all__'
